/*
 * @Author: your name
 * @Date: 2021-10-20 09:40:15
 * @LastEditTime: 2021-10-20 10:51:29
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \Vuec:\Users\86131\Desktop\project\payforknowledge\src\store\hot\index.js
 */
import { hotList2 } from "../../utils/api";

const hotListModule = {
  state: {
    hotList: [],
  },
  mutations: {
    changeHotList(state, payload) {
      state.hotList = payload.result;
    },
  },
  actions: {
    async getHotList({ commit }) {
      const res = await hotList2();

      commit("changeHotList", res);
    },
  },
};

export default hotListModule;
